/**
 * There are <a href="https://github.com/thinkgem/jeesite">JeeSite</a> code generation
 */
package com.chlitina.store.modules.expert.entity;

import com.chlitina.store.common.persistence.BaseEntity;

/**
 * 方案护理区域季节主键
 * @author liujiang
 * @version 2014-02-18
 */
public class SolutionFaceFoodLsPK extends BaseEntity {
	
	private static final long serialVersionUID = 1L;
	private SolutionFace solutionFace; 	// 方案
	private Product product; 	// 名称
	private SystemDefinitionAreaSeason systemDefinitionAreaSeason;	//区域季节 
	
	public SolutionFaceFoodLsPK() {
	}

	public SolutionFaceFoodLsPK(SolutionFace solutionFace, Product product, SystemDefinitionAreaSeason systemDefinitionAreaSeason) {
		this.solutionFace = solutionFace;
		this.product = product;
		this.systemDefinitionAreaSeason = systemDefinitionAreaSeason;
	}

	public SolutionFace getSolutionFace() {
		return solutionFace;
	}


	public void setSolutionFace(SolutionFace solutionFace) {
		this.solutionFace = solutionFace;
	}

	public Product getProduct() {
		return product;
	}

	public void setProduct(Product product) {
		this.product = product;
	}
	
	public SystemDefinitionAreaSeason getSystemDefinitionAreaSeason() {
		return systemDefinitionAreaSeason;
	}

	public void setSystemDefinitionAreaSeason(SystemDefinitionAreaSeason systemDefinitionAreaSeason) {
		this.systemDefinitionAreaSeason = systemDefinitionAreaSeason;
	}
	
	@Override
	public int hashCode() {
		return this.solutionFace.hashCode() + this.product.hashCode() + this.systemDefinitionAreaSeason.hashCode();
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		final SolutionFaceFoodLsPK other = (SolutionFaceFoodLsPK) obj;
		if (solutionFace.getId() == other.getSolutionFace().getId() &&
				product.getId() == other.getProduct().getId() &&
				systemDefinitionAreaSeason.getId() == other.getSystemDefinitionAreaSeason().getId()) {
			return true;
		} 
		return false;
	}
}
